<script>
	$('#select-all').click(function(event) {   
			if(this.checked) {
					// Iterate each checkbox
					$(':checkbox').each(function() {
							this.checked = true;                        
					});
			}
	});
	
	$('#myModal').on('show', function (e) {
	if (!data) return e.preventDefault() // stops modal from being shown
	})
</script>
<ul class="breadcrumbs">
    <li><a href="dashboard.html"><i class="iconfa-home"></i></a> <span class="separator"></span></li>
    <li>Danh Sách Tài Khoản</li>
</ul>

<div class="pageheader">
    <form action="results.html" method="post" class="searchbar" />
        <input type="text" name="keyword" placeholder="To search type and hit enter..." />
    </form>
    <div class="pageicon"><span class="iconfa-table"></span></div>
    <div class="pagetitle">
        <h1>Danh Sách Tài Khoản</h1>
        <h5>Hệ thống quản trị</h5>
    </div>
</div><!--pageheader-->

<div class="maincontent">
    <div class="maincontentinner">
    		<div class="btn-group">
          <button data-toggle="dropdown" class="btn btn-primary"><i class="iconfa-th"></i> &nbsp; Thao tác nhanh <span class="caret"></span></button>
          <ul class="dropdown-menu">
            <li><a href="#"><i class="icon-trash"></i> &nbsp;Xóa mục chọn</a></li>
            <li class="divider"></li>
            <strong style="margin-left:10px">TRẠNG THÁI</strong>
            <li><a href="#"><i class="iconfa-check"></i> &nbsp;Kích hoạt mục chọn</a></li>
            <li><a href="#"><i class="iconfa-check-empty"></i> &nbsp;Ngưng kích hoạt mục chọn</a></li>
          </ul>
        </div>
        <a href="#myModal" role="button" class="btn" data-toggle="modal"><i class="icon-plus"></i></a>
        <table id="dyntable" class="table table-bordered">
            <colgroup>
              <col class="con0" style="align: center; width: 4%" />
              <col class="con1" />
              <col class="con0" />
              <col class="con1" />
              <col class="con0" />
              <col class="con1" />
            </colgroup>
            <thead>
              <tr>
                <th class="head0 nosort"><input type="checkbox" class="checkall" id="select-all" /></th>
                <th class="head0">Tài Khoản</th>
                <th class="head1">Trạng thái</th>
                <th class="head0" style="text-align:center">Thao tác</th>
              </tr>
            </thead>
            <tbody>
            	<?php foreach($this->show_user as $key){?>
                <tr class="gradeX">
                  <td class="aligncenter">
                    <span class="center"><input type="checkbox" id="checkbox"/></span>
                  </td>
                  <td>
										<?php echo $key['userName'] .'-'. $key['fullname'] ?><br />
                   	<em style="color:#936">( Nhóm : <?php echo $key['userName']?>, Email : <?php echo $key['email']?> )</em>
									</td>
                  <td><?php echo $key['status']==1 ? "Kích hoạt" : "ngưng kích hoạt" ?></td>
                  <td style="text-align:center">
                  	<a class="btn btn-primary" href=""><i class="iconfa-wrench"></i></a>
                    <a class="btn " href=""><i class="icon-trash"></i></a>
                  </td>
                </tr>
              <?php }?>
            </tbody>
        </table>
        <div class="footer">
            <div class="footer-left">
                <span>&copy; 2013. Shamcey Admin Template. All Rights Reserved.</span>
            </div>
            <div class="footer-right">
                <span>Designed by: <a href="http://themepixels.com/">ThemePixels</a></span>
            </div>
        </div><!--footer-->
    
    </div><!--maincontentinner-->
</div><!--maincontent-->
<?php include('add.phtml'); ?>